for s in range(100,1000):
    a=s//100
    b=s%10
    c=s%10
    if a**3+b**3+c**3==s:
        print("{}是水仙花数".format(s))